﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage.Master" AutoEventWireup="true"
    Codebehind="NetApplyInvoice.aspx.cs" Inherits="Ankin.EHBH.Web.Modules.Apply.NetApplyInvoice"
    Title="无标题页" %>

<asp:Content ID="Content1" ContentPlaceHolderID="cphcenter" runat="server">

    <script src="../../js/jquery-1.3.2.min.js" type="text/javascript"></script>

    <script src="../../js/jquery.flexselect.js" type="text/javascript"></script>

    <script src="../../js/liquidmetal.js" type="text/javascript"></script>

    <script src="../../js/popup.js" type="text/javascript"></script>

    <script type="text/javascript">
      $(document).ready(function() {
        $("select[class*=flexselect]").flexselect();
        
       
        
        /*测试COOKIES*/
        if($.cookie('popupStatus')==1)
        {
            disablePopup();
            centerPopup();
            loadPopup();
        }
        //写Cookies
        $('#wCookies').click(function(){
		$.cookie('name', 'test11213',{expires: 7});				  
		});
		//读Cookies
		$('#rCookies').click(function(){
		var test = $.cookie('popupStatus');
		alert (test);
		});
		
		$('#rCookies1').click(function(){
		var test = $.cookie('popupStatus');
		alert (test);
		});
		//删除
		$('#dCookies').click(function(){
		$.cookie('popupStatus', '0',{expires: 7});							  
		});
		
      });




function addmx_onclick() {

}

    </script>
     
    <table cellspacing="0" cellpadding="0" width="100%" border="0">
      
            <tr>
                <td class="right-color">
                    网上请领—新建请领</td>
            </tr>
            <tr>
                <td>&nbsp;
                </td>
            </tr>
            <tr>
                <td>
                    <table cellspacing="0" cellpadding="0" width="100%" border="0" class="t1">
                      
                            <tr>
                                <td colspan="7" class="bor bor-bg">
                                    医用耗材请领信息</td>
                            </tr>
                            <tr>
                                <td align="right">
                                    申请单号：</td>
                                <td>
                                    <asp:Label ID="lblBillID" runat="server" Text="Label"></asp:Label></td>
                                <td align="right">
                                    申请日期：</td>
                                <td>
                                    <asp:Label ID="lblDate" runat="server" Text="Label"></asp:Label></td>
                                <td align="right">
                                    申请类型：</td>
                                <td  colspan="2">
                                <asp:DropDownList ID="ddlApply_Type" runat="server">
                            </asp:DropDownList>
                                    </td>
                            </tr>
                            <tr>
                                <td align="right">
                                    申请部门：</td>
                                <td>
                                    <asp:Label ID="lblDept" runat="server"></asp:Label>
                                </td>
                                <td align="right">
                                    下属部门：</td>
                                <td >
                                    <asp:Label ID="lblDownDept" runat="server"></asp:Label></td>
                                <td align="right">
                                    申请人：</td>
                                <td colspan="2">
                                    <asp:Label ID="lblApplier" runat="server" Text="Label"></asp:Label></td>
                            </tr>
                            <tr>
                                <td align="right">
                                    备注：</td>
                                <td colspan="6">
                                <asp:TextBox ID="txtMemo" runat="server" TextMode="MultiLine" Width="98%" Height="100px"></asp:TextBox>
                                </td>
                            </tr>
                      
                    </table>
                </td>
            </tr>
            <tr>
                <td align="center"><br />
                     <input type="button" value="添加明细" id="addmx" class="longbutton" style="width: 90px;
                                    height: 25px; cursor: pointer;" onclick="return addmx_onclick()" /><br /><br />
                                                        <asp:HiddenField ID="hdfStore_Id" runat="server" />
                    <asp:HiddenField ID="hdfBill_Id" runat="server" />
                    <asp:HiddenField ID="hdfApply_Type" runat="server" />
                    <asp:HiddenField ID="hdfDept_Code" runat="server" />
                    <asp:HiddenField ID="hdfApplier" runat="server" />
                    <asp:HiddenField ID="hfdStatus" runat="server" />
                    <asp:HiddenField ID="hdfCreate_Date" runat="server" />
                    <asp:HiddenField ID="hdfOperator" runat="server" />
                    <asp:HiddenField ID="hdfInfo_ID" runat="server" Value="noSelect"></asp:HiddenField>
                </td>
            </tr>
       </table>
                    <table cellspacing="0" cellpadding="0" width="100%" border="0">

                            <tr>
                                <td style="height: 18px" class="bor bor-bg">
                                    请领单明细</td>
                            </tr>
                            <tr>
                                <td style="padding:13px;" class="bor">
                                    <asp:GridView ID="grvApplyDetail" runat="server" AutoGenerateColumns="False" DataKeyNames="INFO_ID"
                                        OnRowCreated="grvApplyDetail_RowCreated" OnRowDataBound="grvApplyDetail_RowDataBound"
                                        OnRowDeleting="grvApplyDetail_RowDeleting" Width="100%" OnRowCommand="grvApplyDetail_RowCommand">
                                         <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                                        <RowStyle CssClass="gv-first-line"/>
                                         <PagerStyle CssClass="fy" />
                                      <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="Black" />
                                      <HeaderStyle  CssClass="gv-head" />
                                      <EditRowStyle BackColor="Black" />
                                      <AlternatingRowStyle BackColor="White" />
                                        <Columns>
                                            <asp:BoundField HeaderText="基本信息号" DataField="INFO_ID">
                                            <ControlStyle CssClass="hidden" />
                                            <FooterStyle CssClass="hidden" />
                                            <HeaderStyle CssClass="hidden" />
                                            <ItemStyle CssClass="hidden" />
                                            </asp:BoundField>                                            
                                            <asp:BoundField HeaderText="产品代码" />
                                            <asp:BoundField HeaderText="产品名称" />
                                            <asp:BoundField HeaderText="规格型号" />
                                            <asp:BoundField HeaderText="产品分类" />
                                            <asp:BoundField HeaderText="报价" />
                                            <asp:BoundField HeaderText="单位" />
                                            <asp:BoundField HeaderText="包装" />
                                            <asp:TemplateField HeaderText="申请数量">
                                                <ItemTemplate>
                                                    <asp:TextBox ID="txtQuan" runat="server" Width="50" AutoPostBack="true" OnKeyPress="if(((event.keyCode>=48)&&(event.keyCode <=57) )) {event.returnValue=true;} else{event.returnValue=false;}"
                                                        OnTextChanged="txtQuan_TextChanged"></asp:TextBox>
                                                </ItemTemplate>
                                            </asp:TemplateField>
                                            <asp:ButtonField ButtonType="Button" ControlStyle-CssClass="button1"  HeaderText="编辑" Text="编辑" />
                                           
                                            
                                       <asp:TemplateField HeaderText="删除">
                                         <ItemTemplate>
                                          <table border="0" cellspacing="0" cellpadding="0" align="center">
                                              <tr>
                                                <td> 
                                                  <asp:Button ID="LinkButton1" runat="server" CausesValidation="False" CommandName="Delete" OnClientClick="return confirm('确认要删除吗？');" 
                                                      Text="删除" CssClass="button1">
                                                  </asp:Button>
                                                  </td>
                                              </tr>
                                          </table>
                                              </ItemTemplate>
                                          </asp:TemplateField>
                                        </Columns>
                                    </asp:GridView>
                <table cellspacing="0" cellpadding="0" width="100%" border="0" style="margin-top:14px;">                    
               <tr>
                <td align="center">
                       <asp:Button ID="btnSaveApply" runat="server" Text="提交请领单" class="longbutton"  OnClick="btnSaveApply_Click">
                    </asp:Button>
                </td>
            </tr>
            </table>
                                    </td>
                            </tr> 
                    </table>
                
        <div id="popupContact" style="width:760px;">
        

    <table cellspacing="0" cellpadding="0" width="100%" border="0">
        <tr>
            <td class="right-color">
                请领信息---医用耗材请领</td>
        </tr>
    </table>
    <table cellspacing="0" cellpadding="0" width="100%" border="0" style="margin-top: 14px;">
        <tr>
            <td colspan="7" class="bor bor-bg">
                医用耗材请领信息</td>
        </tr>
        <tr>
            <td class="bor">
                <table cellspacing="0" cellpadding="0" width="100%" border="0" class="t1">
                    <tr>
                        <td style="width: 82px">
                            产品类别</td>
                        <td style="width: 152px">
                            <asp:DropDownList ID="ddlPrimClass" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlPrimClass_SelectedIndexChanged">
                            </asp:DropDownList></td>
                        <td style="width: 84px">
                            二级类别</td>
                        <td style="width: 93px">
                            <asp:DropDownList ID="ddlSecClass" runat="server" OnSelectedIndexChanged="ddlSecClass_SelectedIndexChanged"
                                AutoPostBack="True">
                            </asp:DropDownList>
                        </td>
                        <td style="width: 93px">
                            <asp:RadioButton ID="rdbOften" runat="server" AutoPostBack="True" Checked="True"
                                GroupName="Often" OnCheckedChanged="rdbOften_CheckedChanged" Text="常用消耗品" /></td>
                        <td colspan="4">
                            <asp:RadioButton ID="rdbAll" runat="server" AutoPostBack="True" GroupName="Often"
                                OnCheckedChanged="rdbAll_CheckedChanged" Text="全部消耗品" />&nbsp;
                        </td>
                    </tr>
                    <tr>
                        <td>
                            产品名称</td>
                        <td style="width: 152px">
                            <asp:DropDownList ID="ddlExp_Name" runat="server" AutoPostBack="true" CssClass="flexselect">
                            </asp:DropDownList>
                            <div style="display: none">
                                <asp:TextBox ID="TxtExpName" runat="server" OnTextChanged="TxtExpName_TextChanged"
                                    AutoPostBack="True"></asp:TextBox>
                            </div>
                        </td>
                        <td>
                            规格型号</td>
                        <td style="width: 93px">
                            <asp:DropDownList ID="ddlSpecs" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlSpecs_SelectedIndexChanged">
                                <asp:ListItem></asp:ListItem>
                            </asp:DropDownList></td>
                        <td style="width: 93px">
                            </td>
                        <td colspan="4">
                            <asp:DropDownList ID="ddlFactory" runat="server" AutoPostBack="true" CssClass="flexselect" Visible="False">
                            </asp:DropDownList></td>
                    </tr>
                    <tr>
                        <td align="center" colspan="9">
                            <asp:Button ID="txtSearch" runat="server" Text="查询" OnClick="txtSearch_Click" CssClass="button"
                                Width="57" Height="25" Style="cursor: pointer;" /></td>
                    </tr>
                </table>
            </td>
        </tr>
    </table>
    <table cellspacing="0" cellpadding="0" width="100%" border="0" style="margin-top: 14px;">
        <tr>
            <td class="bor bor-bg">
                请领单明细</td>
        </tr>
        <tr>
            <td class="bor" style="padding: 13px;">
                <asp:GridView ID="grvList" runat="server" AutoGenerateColumns="False" DataKeyNames="INFO_ID"
                    OnRowCommand="grvApplyDetail_RowCommand1" OnRowDataBound="grvApplyDetail_RowDataBound1"
                    Width="100%" OnRowCreated="grvApplyDetail_RowCreated1" AllowPaging="True" OnPageIndexChanging="grvApplyDetail_PageIndexChanging1"
                    AllowSorting="True"
                    PageSize="15">
                    <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                    <RowStyle CssClass="gv-first-line" />
                    <EmptyDataTemplate>
                        <table width="100%">
                            <tr>
                                <td align="center" class="jg">
                                    对不起，没有找到任何相关记录
                                </td>
                            </tr>
                        </table>
                    </EmptyDataTemplate>
                    <Columns>
                        <asp:BoundField HeaderText="基本信息号" DataField="INFO_ID">
                            <ControlStyle CssClass="hidden" />
                            <FooterStyle CssClass="hidden" />
                            <HeaderStyle CssClass="hidden" />
                            <ItemStyle CssClass="hidden" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="产品代码">
                            <ItemStyle Width="60px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="产品名称">
                            <ItemStyle Width="200px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="规格型号">
                            <ItemStyle Width="80px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="生产厂家" >
                            <ItemStyle Width="180px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="产品分类">
                            <ItemStyle Width="180px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="报价">
                            <ItemStyle Width="50px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>                       
                        <asp:BoundField HeaderText="单位">
                            <ItemStyle Width="30px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:BoundField HeaderText="包装">
                            <ItemStyle Width="100px" />
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:BoundField>
                        <asp:TemplateField HeaderText="请领数量">
                            <ItemTemplate>
                                <asp:TextBox ID="txtQuan" runat="server" AutoPostBack="true" OnTextChanged="txt_Quan_TextChanged" OnKeyPress="if(((event.keyCode>=48)&&(event.keyCode <=57) )) {event.returnValue=true;} else{event.returnValue=false;}"
                                    Width="50"></asp:TextBox>
                            </ItemTemplate>
                            <HeaderStyle HorizontalAlign="Center" />
                        </asp:TemplateField>
                        <asp:BoundField HeaderText="现有库存">
                        </asp:BoundField>
                        <asp:BoundField HeaderText="包装数量">
                            <ControlStyle CssClass="hidden" />
                            <FooterStyle CssClass="hidden" />
                            <HeaderStyle CssClass="hidden" />
                            <ItemStyle CssClass="hidden" />
                        </asp:BoundField>
                    </Columns>
                    <PagerStyle CssClass="fy" />
                    <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="Black" />
                    <HeaderStyle CssClass="gv-head" />
                    <EditRowStyle BackColor="Black" />
                    <AlternatingRowStyle BackColor="White" />
                    <PagerSettings Mode="NumericFirstLast" FirstPageText="首页" LastPageText="末页" />
                </asp:GridView>
            </td>
        </tr>
    </table>
    <table cellspacing="0" cellpadding="0" width="100%" border="0" style="margin-top: 14px;">
        <tr>
            <td>
                <center>
                    <asp:Button ID="btnView" runat="server" Text="确定" OnClick="btnView_Click"
                        CssClass="longbutton" Width="90" Height="25" Style="cursor: pointer;"></asp:Button>
                    <input name="" id="btnClosePop" type="button" value="返回" class="longbutton" style="cursor:pointer; width:90px; height:25px;" /></center>
                &nbsp;
                <asp:Label ID="lblVaildsave" runat="server" ForeColor="Red"></asp:Label>
                &nbsp;&nbsp;
                <br />
                <asp:HiddenField ID="hfdInfo_Id" runat="server" />
                <asp:HiddenField ID="hdfExp_Code" runat="server" />
                <asp:HiddenField ID="hdfExp_Name" runat="server" Value="noSelect" />
            </td>
        </tr>
    </table>
        
    </div>
    <div id="backgroundPopup">
    </div>
</asp:Content>
